<template>
	<view class="p20 h100vh">
		<scroll-view scroll-y="true" class="scroll-view oy-auto  pr h100 " @scrolltolower="getMore">
			<view class="p20 bag--fff mt20 br--20" v-for="item in list"
				@click="goto(`/pages/index/PublicDetails?id=${item.id}&gkzp=${0}`)">
				<view class="fw f14">
					{{item.title}}
				</view>
				<view class=" mt20 f12 co--999">
					{{item.updated_at}}
				</view>
			</view>
			<view class="center fs12 co--999 mt10">
				上滑加载更多
			</view>
		</scroll-view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: 'Hello',
				pageNo: 1,
				list: []
			}
		},
		onLoad() {
			this.getlist()
		},
		methods: {
			getMore() {
				this.pageNo++
				this.getlist()
				console.log('1')
			},
			async getlist() {
				let {
					data
				} = await this.$rqt.announcementLists({
					page_no: this.pageNo,
				})
				console.log(data.lists)
				this.list.push(...data.lists)
			},
		}
	}
</script>

<style>

</style>